//
//  FXTHeader.h
//  OfferJob
//
//  Created by 郑州动力无限科技 on 2017/6/30.
//  Copyright © 2017年 郑州动力无限科技. All rights reserved.
//

#ifndef FXTHeader_h
#define FXTHeader_h

#import "AppDelegate.h"
///弱引用，强应用，主要用于block里面，现在block弱引用self，再在block里面强引用
#define WS(__KEY)  __weak typeof(self)__KEY = self
#define SW(__SW,__WS)  __strong typeof(__WS)__SW = __WS
#define mUserDefaults       [NSUserDefaults standardUserDefaults]
#define mNotificationCenter [NSNotificationCenter defaultCenter]
#pragma mark - Basic
#define NavigationBar_BarHeight  64
#define NavigationBar_HEIGHT 44
#define TabBar_HEIGHT 49.0
#define SCREEN_WIDTH ([UIScreen mainScreen].bounds.size.width)
#define SCREEN_HEIGHT ([UIScreen mainScreen].bounds.size.height)
#define kAppScale SCREEN_WIDTH/375.0f
/*
 文本
 */
#define kButtonFont 18 *kAppScale
CG_INLINE CGFloat CurrentScreenScale()
{
    CGRect mainFrme = [[UIScreen mainScreen] bounds];
    return mainFrme.size.width/375.0;
}
//G－C－D
#define BACK(block) dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), block)
#define MAIN(block) dispatch_async(dispatch_get_main_queue(),block)
//images methods
#define ImageNamed(_pointer) [UIImage imageNamed:_pointer]
#pragma mark - color functions
#define RGBCOLOR(r,g,b) [UIColor colorWithRed:(r)/255.0f green:(g)/255.0f blue:(b)/255.0f alpha:1]
#define NavCOLOR [UIColor colorWithRed:32/255.0f green:158/255.0f blue:133/255.0f alpha:1]
#define RGBACOLOR(r,g,b,a) [UIColor colorWithRed:(r)/255.0f green:(g)/255.0f blue:(b)/255.0f alpha:(a)]
// rgb颜色转换（16进制->10进制）
#define UIColorFromHexValue(hexValue) [UIColor colorWithRed:((float)((hexValue & 0xFF0000) >> 16))/255.0 green:((float)((hexValue & 0xFF00) >> 8))/255.0 blue:((float)(hexValue & 0xFF))/255.0 alpha:1.0]
#define Location_City @"locationcity"

#endif /* FXTHeader_h */
